﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Windows.Forms;
using System.Text;
using System.Net.Sockets;
using System.IO;
using System.ServiceModel;

namespace Client
{
    static class Program
    {
        /// <summary>
        /// The main entry point for the application.
        /// </summary>
        [STAThread]
        static void Main()
        {
            ChatServerClient client;

            Application.EnableVisualStyles();
            Application.SetCompatibleTextRenderingDefault(false);
            if (Client.Properties.Settings.Default.Domain != "")
            {
                client = new ChatServerClient("WSHttpBinding_IChatServer", Client.Properties.Settings.Default.Domain);
                Application.Run(new ClientBase(client));
                client.Close();
            }
            else
            {
                MessageBox.Show("Please configure a domain name");
                Application.Run(new Options());
            }
            

            

        }
    }
}
